// the network position. So we shove the end of the timespan out to
// ensure the right edge of that time slider includes us.
//
- time_max = realtime_positioning ? kml_time_max + 600 : kml_time_max;
+ time_max.setTime_t(realtime_positioning ? kml_time_max.toTime_t() + 600 : kml_time_max.toTime_t());
writer->writeTextElement("end", time_max.toPrettyString());
}
writer->writeEndElement(); // Close gx:TimeSpan tag
return toTime_t();
}
- DateTime operator+(quint64 seconds) {
- return DateTime::fromMSecsSinceEpoch(toMSecsSinceEpoch() + seconds*1000);
- }
-
- DateTime operator-(quint64 seconds) {
- return DateTime::fromMSecsSinceEpoch(toMSecsSinceEpoch() - seconds*1000);
- }
-
// Integer form: YYMMDD
int ymd() const {
QDate d(date());
pin = wpt->icon_descr;
} else if (wpt->icon_descr.contains("-unfound")) {
pin = unfoundmarker;
- } else if (wpt->GetCreationTime() > current_time() - 3600 * 24 * thresh_days) {
+ } else if (wpt->GetCreationTime().toTime_t() > current_time().toTime_t() - 3600 * 24 * thresh_days) {
pin = newmarker;
} else {
pin = oldmarker;
if (!wpt->creation_time.isValid()) {
return (double) 0;
} else {
- return ((double)wpt->creation_time.toMSecsSinceEpoch()) / 1000.0;
+ return (double)wpt->creation_time.toTime_t();
}
}